//
//  TicketCodeCell.m
//  ImGuider
//
//  Created by 王鹏宇 on 2017/12/14.
//  Copyright © 2017年 AudioCtrip. All rights reserved.
//

#import "TicketCodeCell.h"

@implementation TicketCodeCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
    
    self.tipLabel.textColor = kContentColor;
    self.codeLabel.textColor = kThemeColor;
    self.tipLabel.text = MYLocalizedString(@"TICKET_TYPE_PSW", nil);
}

- (void)configDataWith:(CompeleteTicketeModel *)model {
    
    if (model.type.integerValue == 1) {
        
        self.codeLabel.text = model.value;
        self.codeImageView.hidden = YES;
    }else if(model.type.integerValue == 2){
        [self.codeImageView setImageURL:[NSURL URLWithString:model.value] placeholderImage:kPlaceholderSqu];
        self.codeImageView.hidden = NO;
    }
    
}
@end
